package com.hospital.controller;


import com.hospital.configure.Result;
import com.hospital.entity.FeeRecord;
import com.hospital.service.FeeRecordService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author WuLiting
 * @since 2021-03-24
 */
@RestController
@RequestMapping("/feeRecord")
public class FeeRecordController {

    @Autowired
    FeeRecordService feeRecordService;

    /**
     * 添加/修改
     */
    @RequestMapping("/updateFeeRecord")
    public Result<FeeRecord> updateFeeRecord(@RequestBody FeeRecord feeRecord) {
        return feeRecordService.updateFeeRecord(feeRecord);
    }

    /**
     * 删除
     */
    @RequestMapping("/delFeeRecord")
    public Result<FeeRecord> delFeeRecord(@RequestBody FeeRecord feeRecord) {
        return feeRecordService.delFeeRecord(feeRecord);
    }

    /**
     * 批量删除
     */
    @RequestMapping("/batchDelFeeRecord")
    public Result<FeeRecord> batchDelFeeRecord(@RequestBody FeeRecord feeRecord) {
        return feeRecordService.batchDelFeeRecord(feeRecord);
    }

    /**
     * 查询(不分页)
     */
    @RequestMapping("/queryFeeRecord")
    public Result<FeeRecord> queryFeeRecord(@RequestBody FeeRecord feeRecord) {
        return feeRecordService.queryFeeRecord(feeRecord);
    }

    /**
     * 查询(分页)
     */
    @RequestMapping("/queryFeeRecordByPage")
    public Result<FeeRecord> queryFeeRecordByPage(@RequestBody FeeRecord feeRecord) {
        return feeRecordService.queryFeeRecordByPage(feeRecord);
    }

    /**
     * 根据ID查询
     */
    @RequestMapping("/queryFeeRecordById")
    public Result<FeeRecord> queryFeeRecordById(@RequestBody FeeRecord feeRecord) {
        return feeRecordService.queryFeeRecordById(feeRecord);
    }

}

